package com.ruoyi.client.mapper;

import com.ruoyi.client.pojo.form.NovelInsertForm;
import com.ruoyi.client.pojo.vo.NovelRewardsVo;
import com.ruoyi.novel.domain.Novels;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository("ClientNovelRewardsMapper")//避免与后台管理重名
public interface NovelRewardsMapper {
    /*增加评论*/
    int insert(Novels novels);


    /*更改评论*/

    int update(Novels novels);

    /*查询所有评论*/
    List<NovelRewardsVo> selectAll();
    /*查询评论列表*/
    List<NovelRewardsVo> selectList(Novels novels);
    /*查看评论*/
    List<NovelRewardsVo> selectVoMyList(Novels novels);

    /*删除评论*/

    int  deleteByPrimaryKey(Long rewardsId);

    NovelRewardsVo selectNovelById(Long rewardId);

    /*点赞评论（增加点赞数）*/
    int incrementAmount(Long rewardId);

    /*取消点赞（减少点赞数）*/
    int decrementAmount(Long rewardId);
}